package com.mmx.mapper;


import com.mmx.domain.entity.FlowDefinition;
import org.apache.ibatis.annotations.Mapper;

/**
 * @desc: 流程定义
 * @author: liushuai
 * @date: 2023/1/24 20:43
 */
@Mapper
public interface FlowDefinitionMapper  {
    /**
     * 新增流程定义
     * @param flowDefinition
     * @return: java.lang.Long
     * @Author: liushuai
     * @Date: 2023/1/31 11:21
     */
    Long insertFlowDefinition(FlowDefinition flowDefinition);

    /**
     * 根据流程定义Key查询最新流程定义
     * @param definitionKey
     * @return: com.mmx.domain.entity.FlowDefinition
     * @Author: liushuai
     * @Date: 2023/1/31 10:59
     */
    FlowDefinition selectFlowDefinitionByDefinitionKey(String definitionKey);
    /**
     * 根据流程实例Id获取流程定义
     * @param instanceId
     * @return: com.mmx.domain.entity.FlowDefinition
     * @Author: liushuai
     * @Date: 2023/3/30 16:21
     */
    FlowDefinition selectFlowDefinitionByInstanceId(Long instanceId);
}
